package com.example.demo.annotation;

import java.util.Queue;

/**
 * @author liuhe
 * @date 2020/08/25
 */
public class FinalizeTest {


    static class Fdd {
        private byte[] content = new byte[1024 * 1024];

        @Override
        protected void finalize() throws Throwable {
            System.out.println("finalize被执行");
        }
    }

    public static void main(String[] args) {
        for (int i = 0; i < 1000; i++) {
            Fdd fdd = new Fdd();
        }
    }
}
